package com.demo.resourcecode.c13jms;

import javax.jms.Destination;
import javax.jms.TextMessage;
import org.springframework.context.ApplicationContext;
import org.springframework.context.support.ClassPathXmlApplicationContext;
import org.springframework.jms.core.JmsTemplate;

public class MainConsumerTest {

	public static void main(String[] args) throws Exception{
		ApplicationContext act = new ClassPathXmlApplicationContext("jms-consumer.xml");
		JmsTemplate jmsTemplate = (JmsTemplate)act.getBean("jmsTemplate");
		Destination destination = (Destination)act.getBean("destination");
		//TextMessage msg = (TextMessage)jmsTemplate.receive(destination);
		//System.out.println("reviced msg is: " + msg.getText());
	}

}
